package com.ruoyi.business.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.Date;

/**
 * 实验记录对象 experiment_record
 * 
 * @author qiancheng
 * @date 2025-06-13
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName("experiment_record")
public class ExperimentRecord extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 实验记录ID */
    @TableId(value = "id", type = IdType.ASSIGN_ID)
    @JsonSerialize(using = ToStringSerializer.class)
    private Long id;

    /** 所属实验台ID */
    @Excel(name = "所属实验台ID")
    @TableField(value = "lab_id")
    private Long labId;

    /** 所属实验台名称 */
    @Excel(name = "所属实验台名称")
    @TableField(value = "lab_name")
    private String labName;

    /** 所属台架ID */
    @Excel(name = "所属台架ID")
    @TableField(value = "rack_id")
    private Long rackId;

    /** 所属年份 */
    @Excel(name = "所属年份")
    @TableField(value = "belong_year")
    private Integer belongYear;

    /** 所属月份 */
    @Excel(name = "所属月份")
    @TableField(value = "belong_month")
    private Integer belongMonth;

    /** 所属日 */
    @Excel(name = "所属日")
    @TableField(value = "belong_day")
    private Integer belongDay;

    /** 实验开始时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "实验开始时间", width = 30, dateFormat = "yyyy-MM-dd")
    @TableField(value = "start_time")
    private Date startTime;

    /** 实验结束时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "实验结束时间", width = 30, dateFormat = "yyyy-MM-dd")
    @TableField(value = "end_time")
    private Date endTime;


}
